package com.example.nacosdemo.controller;

import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@Slf4j
@RequestMapping("/simple/")
public class SimpleController {

    @GetMapping("qps")
    public String qps(){
        try {
            Thread.sleep(100);
        } catch (InterruptedException e) {
            e.printStackTrace();
        }
        return "简单测试qps";
    }


    @GetMapping("thread")
    public String thread(){
        try {
            Thread.sleep(2*100);
        } catch (InterruptedException e) {
            e.printStackTrace();
        }
        return "简单测试线程";
    }


}
